#include "AbsUI/ConnCfgWidgetFactory.hpp"
#include <cassert>

namespace AbsUI
{

void ConnCfgWidgetFactory::registerConstructor( const Storage::NameString& typeName, const Details::ConnCfgWidgetConstructor& constructor)
{
	this->register_constructor( typeName, constructor);
}

// ---------------------------------------------------------------------------------------------------------------------

bool ConnCfgWidgetFactory::isTypeRegistered( const Storage::NameString& typeName) const
{
	return this->has_constructor_for( typeName);
}

// ---------------------------------------------------------------------------------------------------------------------

ConnectionConfigWidget* ConnCfgWidgetFactory::createConnCfgWidget( const Storage::NameString& typeName) const
{
	return (this->operator[]( typeName))();
}

} // namespace AbsUI
